import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)
const Home = () =>import(/*webpackChunckName:'home'*/'views/home/Home')
const Cart = () =>import(/*webpackChunckName:'home'*/'views/cart/Cart')
const Category = () =>import(/*webpackChunckName:'home'*/'views/category/Category')
const Profile = () =>import(/*webpackChunckName:'home'*/'views/profile/Profile')
const routes =[
    {path:'/home',component:Home},
    {path:'/cart',component:Cart},
    {path:'/category',component:Category},
    {path:'/profile',component:Profile},
    {path:'/',redirect: '/home'},
]
export default new VueRouter({
    mode:'history',
    routes
})